$highlight-color: #07f;

.pcui-contextmenu-clipboard {
    > .pcui-menu-items {
        > .pcui-menu-item {
            > .pcui-menu-item-content {
                > .pcui-menu-item-postfix {
                    flex-grow: 1;
                    text-align: right;

                    &.disabled {
                        display: none;
                    }
                }
            }
        }
    }
}

%pcui-highlight {
    content: '\00a0';
    position: absolute;
    inset: -4px;
    border: 1px dotted $highlight-color;
    z-index: 1;
    pointer-events: none;
}

.pcui-element.pcui-highlight::before {
    @extend %pcui-highlight;
}

.pcui-element.pcui-highlight-flash::before {
    @extend %pcui-highlight;

    animation: pcui-clipboard-flash-animation 200ms ease-in-out forwards;
}

@keyframes pcui-clipboard-flash-animation {
    from { border-color: $highlight-color; }
    to { border-color: rgba($highlight-color, 0.0); }
}

.pcui-label-group,
.pcui-asset-input {
    &:hover {
        > .pcui-label > .pcui-clipboard-button {
            display: block;

            &.pcui-hidden {
                display: none;
            }
        }
    }
}

.pcui-label {
    &:hover {
        > .pcui-clipboard-button {
            display: block;

            &.pcui-hidden {
                display: none;
            }
        }
    }

    > .pcui-clipboard-button {
        display: none;
        position: absolute;
        top: 0;
        right: 0;
        width: 16px;
        height: 16px;
        line-height: 16px;
        margin: 0;
        padding: 0;
        text-align: center;
        border: 0;
        background-color: #364346;

        &::before {
            display: inline-block;
            line-height: 16px;
        }

        &:hover,
        &:focus {
            box-shadow: none;
            background-color: #364346;
        }

        &.pcui-clipboard-button-copy {
            right: 16px;
        }

        &.pcui-hidden {
            display: none;
        }

        &.pcui-disabled {
            opacity: 1;
            color: rgba(#b1b8ba, 0.4);
        }
    }
}

.ui-tooltip {
    > .inner.pcui-tooltip-disabled {
        color: #777;
    }

    &.pcui-tooltip-clipboard {
        z-index: 1002;
    }
}
